package com.example.demo.aiInterface;


import dev.langchain4j.service.MemoryId;
import dev.langchain4j.service.SystemMessage;
import dev.langchain4j.service.UserMessage;
import dev.langchain4j.service.spring.AiService;

import reactor.core.publisher.Flux;
import static dev.langchain4j.service.spring.AiServiceWiringMode.EXPLICIT;

@AiService(wiringMode = EXPLICIT,
        streamingChatModel = "customQwenStreamingChatModel",
        chatMemoryProvider = "chatMemoryProvider",
        contentRetriever = "firstContentRetriever")
public interface ChatAssistant {
    @SystemMessage(fromResource = "aiPrompt/ChatAssistant.txt")
    Flux<String>  chat(@MemoryId String sessionId, @UserMessage String userMessage);

}
